package com.jservice.web.sysOffice;


import com.jfinal.core.Controller;
import com.jservice.framework.dto.Message;
import com.jservice.web.base.JBaseValidator;

public class OfficeValidator extends JBaseValidator {

	@Override
	protected void handleError(Controller controller) {

		controller.setAttr("message", Message.error(controller.getAttr("message")));
		controller.render("/admin/index/error.html");
	}

	@Override
	protected void validate(Controller controller) {

		//----------------------office.name的验证-------------------------
		validateRequired("office.name", "message", "部门名称不得为空!");
		
	}

}
